//
//  MainViewController.swift
//  DYZB
//
//  Created by HOu on 2021/11/18.
//

import UIKit

class MainViewController: UITabBarController {

    override func viewDidLoad() {
        super.viewDidLoad()

        addChildVc(storyName: "Home")
        addChildVc(storyName: "Live")
        addChildVc(storyName: "Follow")
        addChildVc(storyName: "Profile")

    }
    
    private func addChildVc(storyName:String){
        
        //1.通过storyboard获取控制器
        let chidVc = UIStoryboard(name: storyName, bundle: nil).instantiateInitialViewController()!
        //2.将childVc作为子控制器
        addChild(chidVc)
        
    }

    

}
